﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Phoenix.Service;
using Phoenix.Service.Contracts;
using Phoenix.Service.Model;

namespace AdminSite.Controllers
{
    public class CategoryController : Controller
    {

		ICategoryService ICategory = new CategoryService();

        public ActionResult Index()
        {
            return View();
        }

		public ActionResult query_category_children(int pid)
		{
			 IList<CategoryModel>model=ICategory.GetByParentID(pid);

			 return Json(model, JsonRequestBehavior.AllowGet);
		}

    }
}
